package com.improve.frame.log.config;

import com.improve.frame.log.properties.LogDbProperties;
import com.improve.frame.log.properties.LogProperties;
import com.improve.frame.log.properties.TraceProperties;
import com.zaxxer.hikari.HikariConfig;
import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.annotation.Configuration;

/**
 * @Description
 *      日志自动配置
 * @Author wzxing918
 * @Date 2021-03-31
 * @Version 1.0.0
 **/
@EnableConfigurationProperties({TraceProperties.class, LogProperties.class})
public class LogAutoConfigure {
    /**
     * 日志数据库配置
     */
    @Configuration
    @ConditionalOnClass(HikariConfig.class)
    @EnableConfigurationProperties(LogDbProperties.class)
    public static class LogDbAutoConfigure {}
}
